<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<script type="text/javascript">

	function Bottle(name, price, isKeepWarm) {
		this.name = name;
		this.price = price;
		this.isKeepWarm = isKeepWarm;
	}

	Bottle.prototype.sayName = function() {
		console.log(this.name)
	};


	var bottle1 = new Bottle('无敌保温杯', '999', true);
	bottle1.sayName();

	</script>
	<p>请用 f12 查看此 html 的script标签</p>
</body>
</html>